package common.base;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.widget.Toast;

/**
 * Created by yangkuo02 on 2017/6/3.
 */

public class BaseActivity extends AppCompatActivity {

    protected void showToast(String content) {
        Toast.makeText(this, content, Toast.LENGTH_SHORT).show();
    }

    protected void showToast(String content, int duration) {
        Toast.makeText(this, content, duration).show();
    }

    protected void startActivity(Class<?> cls) {
        Intent intent = new Intent(this, cls);
        startActivity(intent);
        this.finish();
    }
}
